<?php

use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class CreateVillagePublishCheckTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('village_publish_check', function (Blueprint $table) {
            $table->increments('id')->comment('乡村在线审核表');
            $table->integer('pub_id')->default(0)->comment('乡村在线文章id');
            $table->integer('check_user_id')->default(0)->comment('审核员id');
            $table->tinyInteger('is_check_admin')->default(0)->comment('审核员是否为管理员');
            $table->string('refuse_reason')->nullable()->comment('未通过原因');
            $table->tinyInteger('status')->default(0)->comment('审核状态：未通过0，已通过1');
            $table->timestamps();
            $table->softDeletes();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::table('village_publish_check', function (Blueprint $table) {
            //
        });
    }
}
